package etr.bk.gui.rpan.info;

import java.awt.Graphics;
import java.awt.event.MouseListener;
import java.awt.image.BufferedImage;

import javax.swing.JPanel;

public class PortraitPane extends JPanel
{
	private BufferedImage img;
	
	

	public PortraitPane(BufferedImage image)
	{
		this.img = image;
	}
	
	public void paintComponent(Graphics g)
	{
		if (this.img != null)
		{
			g.drawImage(img, 0, 0,200,280, null);//+ scaling
		}
		else 
		{
			g.clearRect(0, 0, this.getWidth(),this.getHeight());
		}
	}
	
	public void setImage(BufferedImage image)
	{
		this.img = image;
	}
	
	
	public BufferedImage getImg() {
		return img;
	}
}
